<?php

class Form_Impressao extends Zend_Form
{

	public function init()
	{
		$this->setMethod('Post');
		$this->setAction('');

		$this->filtro1();
		$this->filtroBairroRua();
		$this->filtroAniversario();
		$this->subFiltroAniversario();
		$this->addElement('submit', 'Imprimir');


	}

	public function filtro1(){

		$element = new Zend_Form_Element_Select('Filtro');
		$element->addMultiOption('','');
		$element->addMultiOption('Aniversario','Aniversario');
		$element->addMultiOption('Bairro','Bairro');
		$element->addMultiOption('Rua','Rua');
		$element->setLabel('Filtro:')
		->setAttrib("id", "filtro1");
		$this->addElement($element);
	}

	public function filtroBairroRua(){
		$this->addElement($this->createElement('text', 'vl_filtro',
		array('label'		=> 'Valor:')));
	}


	public function filtroAniversario(){
		$element = new Zend_Form_Element_Radio('filtro_aniversario');
		$element->setLabel('Escolha filtro do aniversario:')
		->addMultiOption('D', 'Dia')
		->addMultiOption('M', 'Mes')
		->addMultiOption('DM','Dia do Mes');
			
		$this->addElement($element);
			
	}

	public function subFiltroAniversario(){
		$this->addElement($this->createElement('text', 'sub_filtro_dia',
		array('label'		=> 'Dia:')));
		$this->addElement($this->createElement('text', 'sub_filtro_mes',
		array('label'		=> 'Mes:')));	
	}

}

